<%@ page pageEncoding="UTF-8"%>
<%
    String path=request.getContextPath();
 %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>温江人大代表之家</title>
<link href="<%=path %>/css/style.css" rel="stylesheet" type="text/css" />
<link href="<%=path %>/css/common.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="<%=path%>/js/jquery1.4.2.js"></script>
<script type="text/javascript" src="<%=path %>/js/main.js"></script>
<script type="text/javascript">
$(function(){
	     var path=document.getElementById("path").value+"/";
		//加载头部栏目
		 $.post("<%=path%>/selectChannel/getTWebCoreChannel.do",{},function(data){
	  		          if(data!=null&&data.length>0){
	  		          var html="";
    		           $(data).each(function(i){
    		        	     html=html+""+this.qita+"<a href='"+path+""+this.dizhi+""+this.channelId+"' target='_parent'>"+this.name+"</a>";
    		        	 if(i!=data.length-1){
    		        		 html=html+"&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp; ";
    		        	 }
    		           });
    		          $("#channel").html(html);
	  		          }
		   			},"json");
});
	//回车事件
	function Keypress(event){
	 var event=window.event?window.event:event; 
	 if(event.keyCode==13){
	 	if($("#tishi").val().length<1){
			alert("请输入查询标题");
			return;
			}
		document.getElementById("textfield").value=$("#tishi").val();
        $("#selInfo").submit();
      } 
  }
	//搜索
	function sous(){
			if($("#tishi").val().length<1){
			alert("请输入查询标题");
			return;
			}
			document.getElementById("textfield").value=$("#tishi").val();
			$("#selInfo").submit();
		};
</script>
</head>
 <body>
<table border="0" align="center" cellpadding="0" cellspacing="0" style="margin-bottom:10px">
  <tr>
    <td><table width="100%" border="0" cellpadding="0" cellspacing="0">
      <tr>
        <td width="410"><img src="<%=path %>/images/logo.png" width="410" height="88" /></td>
        <td><table border="0" align="right" cellpadding="0" cellspacing="0">
            <tr>
            <td align="right"><img src="<%=path %>/images/searchIco.png" width="26" height="24" /></td>
            <td align="center" style="background-image:url(<%=path %>/images/searchBg.png); width:140px"><input type="text" id="tishi" onkeydown="Keypress(event)" style="width:130px; border:0px; margin:0px; background-image:url(<%=path %>/images/searchBg.png); background-position: 0 -3px;" /></td>
            <td align="center"><img id="suos" onclick="javascript:sous();" src="<%=path %>/images/searchBtn.png" width="67" height="24" align="absmiddle" /></td>
          </tr>
        </table></td>
      </tr>
    </table></td>
  </tr>
  <tr>
    <td><img src="<%=path %>/images/header.png" width="967" height="210" /></td>
  </tr>
  <tr>
    <td align="center" style="background-image:url(<%=path %>/images/menuBg.png); height:39px; width:967px"><span class="p14 color2" style="font-weight:bold"><a href="<%=path%>/index.do" target="_parent">首页</a>&nbsp;&nbsp;&nbsp;|&nbsp;&nbsp;<span id="channel"></span></span></td>
  </tr>
</table>
  <form action="<%=path%>/article/getsearchPageQuery.do" id="selInfo" method="post" target="_parent">
  <input type="hidden" name="title" id="textfield"/>
  </form>
    <input type="hidden" value="<%=path%>" id="path"/>
</body>
</html>